﻿using System;
using System.Net;
using System.Windows;
using System.Windows.Controls;
using System.Windows.Documents;
using System.Windows.Ink;
using System.Windows.Input;
using System.Windows.Media;
using System.Windows.Media.Animation;
using System.Windows.Shapes;
using System.Data.Linq.Mapping;
using System.Data.Linq;

namespace Sapro_Project
{
    [Table]
    public class Turma
    {
        public EntityRef<Escola> nomeEsc;
        public Turma() { 
        }
        [Column(IsPrimaryKey=true)]
        public String Codigo
        {
            get;
            set;
        }
        [Association(IsForeignKey = true, Storage = "nomeEsc")]
        public Escola Nome_Esc {
            get
            {
                return nomeEsc.Entity;
            }
            set
            {
                nomeEsc.Entity = value;
            }
        }
    }
}
